#include "bsp.h"

void Meter_Init(void)
{
	bsp_Usart_Init(UART3, 115200);
}

void Meter_Process(void)
{
	
}

void Meter_SendBuf()
{
	u8 buf[26];
	u16 crc;
	
	buf[0] = 0x68;
	buf[1] = 0x01;
	buf[2] = 0x01;
	buf[3] = 0x02;
	buf[4] = 0x03;
	buf[5] = 0x04;
	buf[6] = 0x05;
	buf[7] = 0x06;
	buf[8] = 0x07;
	buf[9] = 0x11;
	buf[10] = 0x12;
	buf[11] = 0x13;
	buf[12] = 0x14;
	buf[13] = 0x21;
	buf[14] = 0x22;
	buf[15] = 0x23;
	buf[16] = 0x24;
	
	crc = CRC16_Modbus(buf,17);
	
	buf[17] = crc >> 8;
	buf[18] = crc;
	buf[19] = 0x16;
	
	Debug_SendData(buf,20);
	
}

